package com.chinacoal.microservice.impl.service;

import java.util.List;
import java.util.Map;

import com.baomidou.mybatisplus.plugins.Page;
import com.baomidou.mybatisplus.service.IService;
import com.chinacoal.microservice.api.model.QueryUtaskParam;
import com.chinacoal.microservice.api.model.UtaskCompleteTaskParam;
import com.chinacoal.microservice.api.model.entity.UtaskInfoEntity;
import com.chinacoal.microservice.util.result.Result;

public interface UtaskInfoService extends IService<UtaskInfoEntity> {

	public Result<Object> addTask(UtaskInfoEntity taskInfoEntity) throws Exception;
	
	public Map<String,List<UtaskInfoEntity>> battchTaskAdd(List<UtaskInfoEntity> taskInfoList) throws Exception;
	
	public void updateTask(UtaskInfoEntity taskInfoEntity) throws Exception;
	
	public void updateAchTask(UtaskInfoEntity taskInfoEntity) throws Exception;
	
	public Map<String,List<UtaskInfoEntity>> battchUpdateTask(List<UtaskInfoEntity> taskInfoList) throws Exception;
	
	public void completeTask(UtaskCompleteTaskParam param) throws Exception;
	
	public Map<String,List<String>> battchCompleteTask(List<UtaskCompleteTaskParam> paramList) throws Exception;
	
	public void cancelTask(UtaskCompleteTaskParam param) throws Exception;
	
	public void cancelAchTask(UtaskCompleteTaskParam param) throws Exception;
	
	public Map<String,List<String>> battchCancelTask(List<UtaskCompleteTaskParam> paramList) throws Exception;
	
	public void updateTaskState(String sysCode, String sysTaskId, String state) throws Exception;
	
	public UtaskInfoEntity getTask(String sysCode, String sysTaskId) throws Exception;
	
	public Page<UtaskInfoEntity> getTaskInfoList(QueryUtaskParam param) throws Exception;;
	
	public Integer getTaskInfoListNum(QueryUtaskParam param) throws Exception;;
	
	public List<Map<String,Object>> selectTaskCountList(QueryUtaskParam param) throws Exception;;
	
	public String getTaskState(String sysCode, String sysTaskId) throws Exception;;
	
	public void collectTask(String userCode, String taskId, String sysCodeFrom, String flag) throws Exception;
	
	public UtaskInfoEntity getUtaskInfoById(String taskId) throws Exception;
}
